
#ifndef COMMAND_PARSER_H
#define COMMAND_PARSER_H

/*
	N01t1I
	N01d1I  / ask for temperature
	N01f1I  / ask for acceleration X
	N01g1I  / ask for acceleration Y
	N01h1I  / ask for acceleration Z
	N01l1I  / ask for Pitch
	N01m1I  / ask for roll
	N01n1I  / ask for yaw
	
	N11r1eI  / ask for PARAMATER_UPPER_TEMPERATURE_THRESHOLD
	N11t1e32.0I  / change PARAMATER_UPPER_TEMPERATURE_THRESHOLD to 32.0
	
	N11t1g2I change  PARAMATER_AUTOMATIC_TEMPERATURE_TRANSMISION_PERIOD to 2
	
*/

typedef struct Message
{
	byte length;
	byte address;
	byte command;
	byte dataFormat;
	byte data[100];
};

//=========================================================================================================
// Command interface values
const int COMMAND_REQUEST_TEMPERATURE 		= 0x64; //DEC 100 //ASCII d
const int COMMAND_RESPONSE_TEMPERATURE 		= 0x65; //DEC 101 //ASCII e

const int COMMAND_REQUEST_ACCELERATION_X	= 0x66; //DEC 102 //ASCII f
const int COMMAND_REQUEST_ACCELERATION_Y	= 0x67; //DEC 103 //ASCII g
const int COMMAND_REQUEST_ACCELERATION_Z	= 0x68; //DEC 104 //ASCII h

const int COMMAND_RESPONSE_ACCELERATION_X	= 0x69; //DEC 105 //ASCII i
const int COMMAND_RESPONSE_ACCELERATION_Y	= 0x6A; //DEC 106 //ASCII j
const int COMMAND_RESPONSE_ACCELERATION_Z	= 0x6B; //DEC 107 //ASCII k

const int COMMAND_REQUEST_PITCH				= 0x6C; //DEC 108 //ASCII l
const int COMMAND_REQUEST_ROLL				= 0x6D; //DEC 109 //ASCII m
const int COMMAND_REQUEST_YAW				= 0x6E; //DEC 110 //ASCII n

const int COMMAND_RESPONSE_PITCH			= 0x6F; //DEC 111 //ASCII o
const int COMMAND_RESPONSE_ROLL				= 0x70; //DEC 112 //ASCII p
const int COMMAND_RESPONSE_YAW				= 0x71; //DEC 113 //ASCII q

const int COMMAND_REQUEST_PARAMETER			= 0x72; //DEC 114 //ASCII r
const int COMMAND_RESPONSE_PARAMETER		= 0x73; //DEC 115 //ASCII s
const int COMMAND_SET_PARAMETER				= 0x74; //DEC 116 //ASCII t

const int COMMAND_SET_ALARM_TEMPERATURE		= 0x75; //DEC 117 //ASCII u
const int COMMAND_SET_ALARM_ACCELERATION_X	= 0x76; //DEC 118 //ASCII v
const int COMMAND_SET_ALARM_ACCELERATION_Y	= 0x77; //DEC 119 //ASCII w
const int COMMAND_SET_ALARM_ACCELERATION_Z	= 0x78; //DEC 120 //ASCII x

const int COMMAND_RESET_ALL_MAX_MIN			= 0x79; //DEC 121 //ASCII y
const int COMMAND_ACKNOWLEDGE				= 0x7A; //DEC 122 //ASCII z
const int COMMAND_ERROR						= 0x23; //DEC 35  //ASCII #

// message constans
const byte MESSAGE_START			= 0x4E;	 // 78 DEC
const byte MESSAGE_END				= 0x49;  // 73 DEC

//=========================================================================================================


#endif COMMAND_PARSER_H

